gdkwindow: Simplify clip region handling
authorAlexander Larsson <alexl@redhat.com>
Wed, 17 Apr 2013 14:36:52 +0000 (16:36 +0200)
committerAlexander Larsson <alexl@redhat.com>
Tue, 7 May 2013 14:33:01 +0000 (16:33 +0200)
commit5773cf237c7bf08f03a308f7952b6cf66840dbc4
treec0f0440ace47c10e4d1d32e59a9f624ac42de366
parent19560bf0d44e6adb03c1cb88bf89b92ce3ea9c8b
gdkwindow: Simplify clip region handling

Since we dropped the move region optimization there is really no need
to try carefully keep track of opaque non-overlapped regions, as we
don't use this information to trigger the optimization anymore.

So, by assuming that all windows are non-opaque we can vastly simplify
the clip region stuff. First of all, we don't need clip_region_with_children,
as each window will need to draw under all children anyway. Secondly, we
don't remove overlapping sibling areas from clip_region, as these are
all non-opaque anyway and we need to draw under them

Finally, we don't need to track the layered region anymore as its
essentially unused. The few times something like it is needed we can
compute it explicitly.

For the case of native children of widgets we may cause a repaint
under native windows that are guaranteed to be opaque, but these
will be clipped by the native child anyway.
gdk/gdkwindow.c